package com.mars.basic.convert;


import com.mars.basic.allmain.entity.PermissionEntity;
import com.mars.basic.allmain.po.Permission;
import com.mars.common.convert.IEntityPOConvert;
import com.mars.common.utils.Beans;
import org.springframework.context.annotation.Lazy;
import org.springframework.stereotype.Component;

@Component
@Lazy
public class PermissionConvert implements IEntityPOConvert<PermissionEntity,Permission> {
    @Override
    public PermissionEntity toEntity(Permission u) {
        return Beans.mapper(u, PermissionEntity.class); }

    @Override
    public Permission toPo(PermissionEntity e) {
        return Beans.mapper(e,Permission.class);
    }
}
